import http from '@/utils/http';

const warehouse = {
  //获取所有仓库
  getWarehouses() {
    let url = '/Warehouse/GetWarehouses';
    return http.get(url);
  },
  //仓库视图
  query(params: any) {
    let url = '/Warehouse/Query';
    return http.post(url, params);
  },
  //仓库详情
  detail(id: Number) {
    let url = '/Warehouse/Detail';
    let params = { id: id };
    return http.get(url, params);
  },
  //仓库保存
  save(role: Object) {
    let url = '/Warehouse/Save';
    return http.post(url, role);
  },
};
export default warehouse;
